package com.sntk.organauthomanager.domain.repository;

import com.sntk.organauthomanager.domain.model.UserResource;
import com.sntk.organauthomanager.domain.model.UserResourceIdentify;

import java.util.List;

public interface UserResourceRepository extends BaseRepository<UserResource, UserResourceIdentify> {

    /**
     * 删除用户私有权限
     * @param uname
     * @param operator
     */
    void deleteAllOfUser(String uname, String operator);

    /**
     * 删除不属于用户关联机构的私有权限
     * @param uname
     * @param organs
     * @param operator
     */
    void deleteAllOfUserNotInOrgan(String uname, List<String> organs, String operator);
}
